<h3 >Lista konobara</h3>
<script>

</script>
<div >
<button class="btn btn-success" ng-click="izmeniKonobara('novi')" data-toggle="modal" href="#editModal">
    <span class="glyphicon glyphicon-plus"></span>&nbsp;Kreiraj novog konobara
</button>
<!--<a ng-model="ZaposleniDetaljiListCtrl" class="btn btn-success" ng-click="izmeniKonobara('novi')" href="#/zaposleniDetalji">
    <span class="glyphicon glyphicon-plus"></span>&nbsp;Kreiraj novog konobara
</a>-->

<div class="pull-right">
    <div class="form-horizontal">
        <div class="form-group">

            <input ng-model="search.$" class="form-control" placeholder="Pronađi zaposlenog">



            <label>Sortirano po imenu:
                <label ng-click="orderByField = 'ime'; reverseSort = !reverseSort">

				<span ng-show="orderByField == 'ime'">
					<span ng-show="!reverseSort" ><span class="glyphicon glyphicon-chevron-down"></span> a-z</span>
					<span ng-show="reverseSort"><span class="glyphicon glyphicon-chevron-up"></span> z-a</span>
				</span>
                </label>
            </label>
        </div>
    </div>
</div>


<div class="clearfix" style="margin-bottom: 16px"></div>

<div class="row" >
    <div class="col-sm-6 col-md-4"
         ng-repeat='konobar in konobari | filter:search:strict | orderBy:orderByField:reverseSort'>
        <div class="thumbnail">
            <img style="height:180px;" class="img-responsive" src="img/{{konobar.slika}}" alt="{{konobar.slika}} ...">
            <div class="caption" onload="JavaScript:timedRefresh(1000);">
                <h3>{{konobar.ime}} {{konobar.prezime}}</h3>
                <p>Godina rodjenja: {{konobar.godinaRodjenja}}</p>
                <p>Mesto rodjenja: {{konobar.mestoRodjenja}}</p>
                <p>Korisnicko ime: {{konobar.korisnickoIme}}</p>

                <div class="btn-group">

                    <a ng-controller="ZaposleniDetaljiListCtrl"
                       href="#/zaposleniDetalji"
                       class="btn btn-success"
                       ng-click="izmena(konobar);">
                           <span class="glyphicon glyphicon-edit"></span>
                            Izmena
                    </a>

                    <button role='button' class="btn btn-danger" ng-click="delete(konobar)">
                        <span class="glyphicon glyphicon-trash"></span> &nbsp;Obriši
                    </button>

                </div>
            </div>
        </div>
    </div>
</div>

<div
        class="modal fade"
        tabindex="-1"
        role="dialog"
        ng-include="'view/zaposleni-detalji.html'"
        id="editModal"
        aria-hidden="true">
</div>
<div class="modal fade"
     tabindex="-1"
     role="dialog"
     ng-include="'view/upload.html'"
     id="editModal2"
     aria-hidden="true">
</div>
</div>